<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <title>管理员组管理</title>
  <meta name="renderer" content="webkit">
  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
  <link rel="stylesheet" href="__ADMIN__css/style.css"  media="all">
  <link rel="stylesheet" href="__ADMIN__layui/css/layui.css"  media="all">
  <style>
.layui-elem-field legend{font-size:18px;}
.layui-form-item .layui-form-checkbox{margin-top:0px;}
.layui-form-checkbox{height:20px;padding-right:20px;line-height:18px;}
.layui-form-checkbox i{width:20px;font-size:14px;}
  </style>
</head>
<body>
<div class="pad-20">
  <fieldset class="layui-elem-field layui-field-title">
  <legend>管理员组管理</legend>
  </fieldset>
  <form class="layui-form" action="" method="post" enctype="multipart/form-data">
    <!--基本信息-->
    <div class="layui-form-item">
      <label class="layui-form-label"><i class="layui-error-ts">*</i> 名称</label>
      <div class="layui-input-inline" style="width:400px;">
        <input class="layui-input newsName" lay-verify="required" placeholder="名称" value="{$info['title']}" type="text" name="data[title]">
      </div>
    </div>
    <div class="layui-form-item">
      <label class="layui-form-label"><i class="layui-error-ts">*</i> 权限</label>
      <div class="layui-input-block">
        <div class="auth_box">
        <foreach name="rule_data" item="v">
            <div class="item clearfix">
              <fieldset class="layui-elem-field">
  <legend>{$v['title']}</legend>
  <div class="layui-field-box">
    <foreach name="v['_data']" item="n">
    <span>{$n['title']} <input type="checkbox" name="rule_ids[]" value="{$n['id']}" <if condition="in_array($n['id'],$group_data['rules'])"> checked="checked"</if>></span>
    </foreach>
  </div>
</fieldset>
            </div>
        </foreach>
        </div>
      </div>
    </div>
    <!--基本信息-->
    <div class="layui-form-item">
      <div class="layui-input-block">
        <div class="layui-form-mid red-error">所有的权限组都必须选择【后台管理模块】下【后台主页】【欢迎页面】否则无法访问后台主页</div>
      </div>
    </div>
    <div class="layui-form-item">
      <div class="layui-input-block">
        <input type="hidden" name="id" value="{$info['id']|default=''}">
        <button class="layui-btn" lay-submit="" lay-filter="addNews">立即提交</button>
        <button type="reset" class="layui-btn layui-btn-primary">重置</button>
        </div>
    </div>
  </form>
</div>
<div class="yzui-filler"></div>
<script src="__ADMIN__js/jquery-1.9.1.min.js" charset="utf-8"></script>
<script src="__ADMIN__layui/layui.js" charset="utf-8"></script>
<!-- 注意：如果你直接复制所有代码到本地，上述js路径需要改成你本地的 -->
<script type="text/javascript">
  layui.use(['form', 'layedit', 'laydate'], function(){
    var form = layui.form
    ,layer = layui.layer
    ,layedit = layui.layedit
    ,laydate = layui.laydate;

  });
  layui.use('element', function(){
  var $ = layui.jquery
  ,element = layui.element;
  });

</script>
</body>
</html>
